export function setPosition (height, isFixed) {
  if (height && height > document.body.clientHeight) {
    isFixed = true
  } else {
    isFixed = false
  }
}

export function getData (el, name, val) {
  const prefix = 'data-'
  name = prefix + name
  if (val) {
    return el.setAttribute(name, val)
  } else {
    return el.getAttribute(name)
  }
}
// export function isAndroid_ios() {
//   const u = navigator.userAgent
//   const app = navigator.appVersion
//   var isAndroid = u.indexOf('Android') > -1 || u.indexOf('Linux') > -1
//   var isiOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/)
//   return isAndroid == true ? true : false
// }
